package Box2D.Dynamics.Joints
{
	import Box2D.Common.Math.b2Vec2;
	import Box2D.Dynamics.b2Body;

	public class b2PrismaticJointDef extends b2JointDef
	{
		private var _localAnchorA:b2Vec2;
		private var _localAnchorB:b2Vec2;
		private var _localAxis1:b2Vec2;		
		
		public function b2PrismaticJointDef()
		{
			super(callDirect('b2PrismaticJointDef_new'));
			_localAnchorA = new b2Vec2(0,0,wrapper+17);
			_localAnchorB = new b2Vec2(0,0,wrapper+25);
			_localAxis1 = new b2Vec2(0,0,wrapper+33);
		}		
		public override function get cls():Class{
			return b2PrismaticJoint;
		}
		public function Initialize(bodyA:b2Body, bodyB:b2Body, anchor:b2Vec2, axis:b2Vec2):void{
			call('b2PrismaticJointDef_Initialize',bodyA.wrapper,bodyB.wrapper,anchor.wrapper,axis.wrapper);
		}
		
		public function get localAnchorA():b2Vec2{return _localAnchorA}
		public function set localAnchorA(value:b2Vec2):void{_localAnchorA.Copy(value)}
		
		public function get localAnchorB():b2Vec2{return _localAnchorB}
		public function set localAnchorB(value:b2Vec2):void{_localAnchorB.Copy(value)}
		
		public function get localAxis1():b2Vec2{return _localAxis1}
		public function set localAxis1(value:b2Vec2):void{_localAxis1.Copy(value)}
		
		public function get referenceAngle():Number{return getNumber(41)}
		public function set referenceAngle(value:Number):void{setNumber(41,value)}
		
		public function get enableLimit():Boolean{return getBoolean(45)}
		public function set enableLimit(value:Boolean):void{setBoolean(45,value)}
		
		public function get lowerTranslation():Number{return getNumber(46)}
		public function set lowerTranslation(value:Number):void{setNumber(46,value)}
		
		public function get upperTranslation():Number{return getNumber(50)}
		public function set upperTranslation(value:Number):void{setNumber(50,value)}
		
		public function get enableMotor():Boolean{return getBoolean(54)}
		public function set enableMotor(value:Boolean):void{setBoolean(54,value)}
		
		public function get maxMotorForce():Number{return getNumber(55)}
		public function set maxMotorForce(value:Number):void{setNumber(55,value)}
		
		public function get motorSpeed():Number{return getNumber(59)}
		public function set motorSpeed(value:Number):void{setNumber(59,value)}
										
	}
}